package com.ly.mpayment.persist.entity;

import java.math.BigDecimal;
import java.util.Date;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import javax.persistence.Version;

import org.hibernate.annotations.GenericGenerator;


/**
 * UpShopInfo entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name="upshopinfo"

)

public class UpShopInfo  implements java.io.Serializable {


    // Fields

     private String upshopuuid;
     private ProvincialInformation provincialInformation;
     private User user;
     private String upshopip;
     private String upkey;
     private String shopnum;
     private Date createtime;
     private Boolean status;
     private BigDecimal upshopbalance;

     private BigDecimal totalMoney;

     private Date modifytime;
     private String orderCommitAddress;
     private String queryBalanceAddress;
     private String orderStatusAddress;
     private String appId;
     private String orderCallAddress;
     private int version;
    //是否转人工 0不是  1人工
    private Boolean artificial;
    //是否压单 1 转压单 0 不压单
    private Boolean pressOrder;
    /**
     * 上游查询开关
     */
    private Boolean querySwitch;
    //重复提交次数
    private Integer repeatNum;

    //通知开关
    private Boolean noticeSwitch;
    //余额通知
    private BigDecimal noticeBalance;

    // Constructors

    /** default constructor */
    public UpShopInfo() {
    }


    /** full constructor */
    public UpShopInfo(ProvincialInformation provincialInformation, User user, String upshopip, String upkey, String shopnum, Date createtime, Boolean status, BigDecimal upshopbalance, String remark, Date modifytime) {
        this.provincialInformation = provincialInformation;
        this.user = user;
        this.upshopip = upshopip;
        this.upkey = upkey;
        this.shopnum = shopnum;
        this.createtime = createtime;
        this.status = status;
        this.upshopbalance = upshopbalance;
//        this.remark = remark;
        this.modifytime = modifytime;
    }

    public UpShopInfo(String upshopuuid, ProvincialInformation provincialInformation, User user, String upshopip, String upkey, String shopnum,
                      Date createtime, Boolean status, BigDecimal upshopbalance, BigDecimal totalMoney, Date modifytime, String orderCommitAddress, String queryBalanceAddress, String orderStatusAddress, String appId, String orderCallAddress, int version) {
        this.upshopuuid = upshopuuid;
        this.provincialInformation = provincialInformation;
        this.user = user;
        this.upshopip = upshopip;
        this.upkey = upkey;
        this.shopnum = shopnum;
        this.createtime = createtime;
        this.status = status;
        this.upshopbalance = upshopbalance;
        this.totalMoney = totalMoney;
        this.modifytime = modifytime;
        this.orderCommitAddress = orderCommitAddress;
        this.queryBalanceAddress = queryBalanceAddress;
        this.orderStatusAddress = orderStatusAddress;
        this.appId = appId;
        this.orderCallAddress = orderCallAddress;
        this.version = version;
    }

    // Property accessors
    @Id
    @GeneratedValue(generator = "uuid")
    @GenericGenerator(name = "uuid", strategy = "uuid")
    @Column(name="upshopuuid", unique=true, nullable=false, length=40)

    public String getUpshopuuid() {
        return this.upshopuuid;
    }

    public void setUpshopuuid(String upshopuuid) {
        this.upshopuuid = upshopuuid;
    }
	@ManyToOne(fetch=FetchType.LAZY)
        @JoinColumn(name="provinceuuid")

    public ProvincialInformation getProvincialInformation() {
        return this.provincialInformation;
    }

    public void setProvincialInformation(ProvincialInformation provincialInformation) {
        this.provincialInformation = provincialInformation;
    }
	@ManyToOne(fetch=FetchType.EAGER)
        @JoinColumn(name="useruuid")

    public User getUser() {
        return this.user;
    }

    public void setUser(User user) {
        this.user = user;
    }

    @Column(name="upshopip", length=40)

    public String getUpshopip() {
        return this.upshopip;
    }

    public void setUpshopip(String upshopip) {
        this.upshopip = upshopip;
    }

    @Column(name="upkey", length=100)

    public String getUpkey() {
        return this.upkey;
    }

    public void setUpkey(String upkey) {
        this.upkey = upkey;
    }

    @Column(name="shopnum", length=40)

    public String getShopnum() {
        return this.shopnum;
    }

    public void setShopnum(String shopnum) {
        this.shopnum = shopnum;
    }

    @Column(name="createtime", length=19)

    public Date getCreatetime() {
        return this.createtime;
    }

    public void setCreatetime(Date createtime) {
        this.createtime = createtime;
    }

    @Column(name="status")

    public Boolean getStatus() {
        return this.status;
    }

    public void setStatus(Boolean status) {
        this.status = status;
    }

    @Column(name="upshopbalance", precision=28, scale=5)

    public BigDecimal getUpshopbalance() {
        return this.upshopbalance;
    }

    public void setUpshopbalance(BigDecimal upshopbalance) {
        this.upshopbalance = upshopbalance;
    }

    @Column(name="total_money", precision=28, scale=5)
    public BigDecimal getTotalMoney() {
        return totalMoney;
    }

    public void setTotalMoney(BigDecimal totalMoney) {
        this.totalMoney = totalMoney;
    }

    //    @Column(name="remark", length=1000)
//    public String getRemark() {
//        return this.remark;
//    }
//
//    public void setRemark(String remark) {
//        this.remark = remark;
//    }

    @Column(name="modifytime", length=19)

    public Date getModifytime() {
        return this.modifytime;
    }

    public void setModifytime(Date modifytime) {
        this.modifytime = modifytime;
    }

    @Column(name="order_commit_address")
	public String getOrderCommitAddress() {
		return orderCommitAddress;
	}


	public void setOrderCommitAddress(String orderCommitAddress) {
		this.orderCommitAddress = orderCommitAddress;
	}

	@Column(name="query_balance_address")
	public String getQueryBalanceAddress() {
		return queryBalanceAddress;
	}

	public void setQueryBalanceAddress(String queryBalanceAddress) {
		this.queryBalanceAddress = queryBalanceAddress;
	}

	@Column(name="order_status_address")
	public String getOrderStatusAddress() {
		return orderStatusAddress;
	}


	public void setOrderStatusAddress(String orderStatusAddress) {
		this.orderStatusAddress = orderStatusAddress;
	}

	@Column(name="appid")
	public String getAppId() {
		return appId;
	}


	public void setAppId(String appId) {
		this.appId = appId;
	}


	@Version
	@Column(name="version")
	public int getVersion() {
		return version;
	}


	public void setVersion(int version) {
		this.version = version;
	}

	@Column(name="order_call_address")
	public String getOrderCallAddress() {
		return orderCallAddress;
	}


	public void setOrderCallAddress(String orderCallAddress) {
		this.orderCallAddress = orderCallAddress;
	}

    @Column(name = "artificial")
    public Boolean getArtificial() {
        return artificial;
    }

    public void setArtificial(Boolean artificial) {
        this.artificial = artificial;
    }

    @Column(name = "press_order")
    public Boolean getPressOrder() {
        return pressOrder;
    }

    public void setPressOrder(Boolean pressOrder) {
        this.pressOrder = pressOrder;
    }


    @Column(name = "query_switch")
    public Boolean getQuerySwitch() {
        return querySwitch;
    }

    public void setQuerySwitch(Boolean querySwitch) {
        this.querySwitch = querySwitch;
    }

    @Column(name = "repeat_num")
    public Integer getRepeatNum() {
        return repeatNum;
    }

    public void setRepeatNum(Integer repeatNum) {
        this.repeatNum = repeatNum;
    }


    @Column(name = "notice_switch")
    public Boolean getNoticeSwitch() {
        return noticeSwitch;
    }

    public void setNoticeSwitch(Boolean noticeSwitch) {
        this.noticeSwitch = noticeSwitch;
    }

    @Column(name = "notice_balance")
    public BigDecimal getNoticeBalance() {
        return noticeBalance;
    }

    public void setNoticeBalance(BigDecimal noticeBalance) {
        this.noticeBalance = noticeBalance;
    }
}
